// pages/notify/index.ts
Page({

  /**
   * 页面的初始数据
   */
  data: {
    announcementDetails: " ",
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad({ id }) {
    // console.log(id);
    this.getAnnouncementDetails(id)
  },
  async getAnnouncementDetails(id) {
    const res = await wx.http({
      url: `/announcement/${id}`
    })
    // console.log(21, res);
    this.setData({
      announcementDetails: res.data
    })
  }
})